-- CALC_EQUIP_8512_PROP

-- 计算锻造铁砧系的基础属性
-- @param user 玩家对象
-- @param classId 装备对象id
return function(user, classId)
    -- 锻造师称号等级
    local pet = user:getActivePet();
    if not pet then
        return {};
    end

    local skillLevel = CareerM.getCareerLevel(pet, 207);
    skillLevel  = math.max(1, skillLevel);
    local value = 25 - skillLevel * 5;

    local prop = {};

    -- 根据称号等级计算属性
    if skillLevel == 3 then
        prop = { {200, "defense", 1, -1,}, {200, "max_hp", 20, -1,}, {101, 1, value, -1,}, };
    elseif skillLevel == 2 then
        prop = { {200, "defense", 1, -1,}, {200, "max_hp", 10, -1,}, {101, 1, value, -1,}, };
    else
        prop = { {200, "defense", 1, -1,}, {101, 1, value, -1,}, };
    end

    -- 附魔师铁砧
    if classId == 8513 then
        table.insert(prop, {818, "magic", 1, -1,});
        return prop;
    end

    -- 铸剑师铁砧
    if classId == 8514 then
        table.insert(prop, {818, "physic", 1, -1,});
        return prop;
    end

    -- 奥术铁砧
    if classId == 8515 then
        table.insert(prop, {818, "forging", 1, -1,});
        return prop;
    end

    return prop;
end